package cn.bdqn.controller;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import cn.bdqn.pojo.Role;
import cn.bdqn.service.RoleService;

@Controller
public class RoleController {
	
	@Autowired
	private RoleService roleService;
	
	@RequestMapping("/showAll.html")
	public String showAll(Model model){
		List<Role> list=roleService.findAll();
		model.addAttribute("roleList", list);
		return "showAll";
	}
}
